CommandRotate Class Reference

#include <CommandRotate.h>

Inheritance diagram for CommandRotate:

Command List of all members.

Public Member Functions

 CommandRotate (float angle, OSGWindows *osgwind)
 CommandRotate (float angle, OSGWindows *osgwind, TraffEduObject *obj)
bool execute ()
bool unexecute ()

Private Attributes

OSGWindows * osgwind_
vector< TraffEduObject * > rotatedObjs_
float angle_
int rightCLK
TraffEduObject * obj_

Constructor & Destructor Documentation

CommandRotate::CommandRotate (  float  angle,
OSGWindows *  osgwind
) 
 

A constructor. Initializes osgwind_ and rightCLK variables. It is called if the rotation operation is done from the menubar.

Parameters:
angle an float argument.
osgwind an OSGWindows pointer.

CommandRotate::CommandRotate (  float  angle,
OSGWindows *  osgwind,
TraffEduObject *  obj
) 
 

A constructor. Initializes osgwind_, obj_, and rightCLK variables. It is called if the rotation operation is done from the menubar.

Parameters:
angle an float argument.
osgwind an OSGWindows pointer.
obj a TraffEduObject pointer.


Member Function Documentation

bool CommandRotate::execute (   )  [virtual]
 

do the rotation operation.

Returns:
Operation success

Implements Command.

bool CommandRotate::unexecute (   )  [virtual]
 

undo the rotation operation.

Returns:
Operation success

Implements Command.


Member Data Documentation

float CommandRotate::angle_ [private]
 

a private variable. It shows how much the selected objects are rotated.

TraffEduObject* CommandRotate::obj_ [private]
 

a private variable. It is used to hold the rotated object.

OSGWindows* CommandRotate::osgwind_ [private]
 

a private variable. It is initialized with the unique OSGWindows instance.

int CommandRotate::rightCLK [private]
 

a private variable. It shows if the CommandRotate is called from the RightClickMenu or not.

vector<TraffEduObject*> CommandRotate::rotatedObjs_ [private]
 

a private vector of TraffEduObjects. It holds the rotated objects.


The documentation for this class was generated from the following file:
Generated on Sun May 28 18:44:00 2006 by  doxygen 1.4.6-NO